﻿<%@ Page Title="" Language="C#" MasterPageFile="~/module/Fontend.Master" AutoEventWireup="true" CodeBehind="AlbumPhoto.aspx.cs" Inherits="mamnontuoitho7.module.AlbumPhoto" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" runat="server">
<div class="purple">
        <a href="Home.aspx">Trang chủ</a> &raquo; Album ảnh</div>
<div class="albumphoto">

<%  if(_dt.Rows.Count >0)
    {
         for (int i = 0; i < _dt.Rows.Count; i++)
        {
    %>
    
    <div class="album">
        <a href="AlbumPhotoDetails.aspx?ProductID=<%=_dt.Rows[i]["ProductID"].ToString()%>">
            <img src="../images/album/album-<%= _dt.Rows[i]["ProductID"].ToString()%>/<%= _dt.Rows[i]["AlbumPhoto"].ToString()%>" 
            alt="<%= (_dt.Rows[i]["AlbumPhoto"].ToString() != "") ? _dt.Rows[i]["AlbumPhoto"].ToString() : "mam non tuoi tho 7" %>" class="img200x150"/>
        </a><br />
        <p><%= _general.ReplaceSpecialCharacters(_general.CutString(_dt.Rows[i]["Title"].ToString(),30))%></p>
        <a href="AlbumPhotoDetails.aspx?ProductID=<%=_dt.Rows[i]["ProductID"].ToString()%>" class="albumlink">Bình luận album này</a>
    </div> 
    <%      }
        }
        else
        { %>
        <div class="commingsoon">
            Dữ liệu đang được cập nhật....
        </div>
        <%} %>
</div>
<div id="container">
    <div class="pagination">

     <%if (_currentbar > 1)
              { %>
            <a href="AlbumPhoto.aspx?a=-1" class="pagepurple"><<</a>
            <%} %>
            <%  

                for (int j = _beginPage; j <= _endPage; j++)
                {
                    if (j == _pageflag)
                    {
            
            %>
            <a href="AlbumPhoto.aspx?page=<%= j%>" class="pagepurple active"><%= j%></a>
            <% }else
               { %>
            <a href="AlbumPhoto.aspx?page=<%= j%>" class="pagepurple"><%= j%></a>
            <%  }
                    } %>
            <%if (_currentbar < _totalBars)
              { %>
            <a href="AlbumPhoto.aspx?a=1" class="pagepurple">>></a>
            <%} %>

    </div>
</div>
</asp:Content>
